<?php
/** Übernommen von: http://www.php.net/manual/en/function.session-destroy.php **/
session_start();

$id = $_SESSION['SessionID'];

include('connect.php');
$sql = mysql_query("UPDATE tblusers SET Timestamp = '0' WHERE ID LIKE '$id'");
$sql = mysql_query("UPDATE tblusers SET Online = '0' WHERE ID LIKE '$id'");

$_SESSION = array();
	
if(ini_get("session.use_cookies")) {
	$params = session_get_cookie_params();
	setcookie(session_name(), '', time() - 42000,
		$params["path"], $params["domain"],
		$params["secure"], $params["httponly"]
	);
}
session_destroy();
?>